home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Champak 99
/
(Vol 99) Jan 19 2010.iso
/
Games
/
arkanoid.swf
/
scripts
/
frame_77
/
DoAction.as
Wrap
Text File
|
2010-01-19
|
3KB
|
129 lines
setProperty("/yellow", _visible, 1);
setProperty("/blue", _visible, 1);
setProperty("/green", _visible, 1);
setProperty("/red", _visible, 1);
level_is = 3;
noOfBricks = 30;
depth = 1;
rows = 0;
cols = 0;
while(rows <= 10)
{
while(cols <= 9)
{
duplicateMovieClip("/red","brick" add cols add rows,16384 + (depth + 16384));
setProperty("brick" add cols add rows, _X, 30 + 40 * cols);
setProperty("brick" add cols add rows, _Y, 20 + 20 * rows);
cols += 1;
depth += 1;
}
cols = 0;
rows += 5;
}
rows = 4;
cols = 2;
while(rows == 4)
{
while(cols <= 9)
{
duplicateMovieClip("/yellow","brick" add cols add rows,16384 + (depth + 16384));
setProperty("brick" add cols add rows, _X, 30 + 40 * cols);
setProperty("brick" add cols add rows, _Y, 20 + 20 * rows);
cols += 1;
depth += 1;
}
rows += 1;
}
rows = 9;
cols = 0;
while(rows == 9)
{
while(cols <= 7)
{
duplicateMovieClip("/yellow","brick" add cols add rows,16384 + (depth + 16384));
setProperty("brick" add cols add rows, _X, 30 + 40 * cols);
setProperty("brick" add cols add rows, _Y, 20 + 20 * rows);
cols += 1;
depth += 1;
}
rows += 1;
}
rows = 14;
cols = 2;
while(rows == 14)
{
while(cols <= 9)
{
duplicateMovieClip("/yellow","brick" add cols add rows,16384 + (depth + 16384));
setProperty("brick" add cols add rows, _X, 30 + 40 * cols);
setProperty("brick" add cols add rows, _Y, 20 + 20 * rows);
cols += 1;
depth += 1;
}
rows += 1;
}
i = 1;
noOfC = 4;
while(noOfC >= i)
{
RandRows = random(11);
RandCols = random(10);
set("c" add i,RandCols add RandRows);
trace("c" add i add " = " add eval("c" add i));
i += 1;
}
i = 1;
noOfE = 1;
while(noOfE >= i)
{
RandRows = random(11);
RandCols = random(10);
set("e" add i,RandCols add RandRows);
trace("e" add i add " = " add eval("e" add i));
i += 1;
}
i = 1;
noOfSL = 1;
while(noOfSL >= i)
{
RandRows = random(11);
RandCols = random(10);
set("sl" add i,RandCols add RandRows);
trace("sl" add i add " = " add eval("sl" add i));
i += 1;
}
i = 1;
noOfB = 2;
while(noOfB >= i)
{
RandRows = random(11);
RandCols = random(10);
set("b" add i,RandCols add RandRows);
trace("b" add i add " = " add eval("b" add i));
i += 1;
}
i = 1;
noOfSH = 1;
while(noOfSH >= i)
{
RandRows = random(11);
RandCols = random(10);
set("sh" add i,RandCols add RandRows);
trace("sh" add i add " = " add eval("sh" add i));
i += 1;
}
i = 1;
noOfF = 1;
while(noOfF >= i)
{
RandRows = random(11);
RandCols = random(10);
set("f" add i,RandCols add RandRows);
trace("f" add i add " = " add eval("f" add i));
i += 1;
}
setProperty("/yellow", _visible, 0);
setProperty("/blue", _visible, 0);
setProperty("/green", _visible, 0);
setProperty("/red", _visible, 0);